﻿using MyFloridaHouse.libSvDTO;
using System.Data;

namespace MyFloridaHouse.DataAccess.Extensions
{
	/// <summary>
	/// RegionDataNameAndValueDTODataContract
	/// </summary>
    class RegionDataNameAndValueDTODataContract
    {
		/// <summary>
		/// DataContract.
		/// </summary>
		/// <param name="rdr">The RDR.</param>
		/// <returns><see cref="RegionDataNameAndValueDTO"/></returns>
        public static RegionDataNameAndValueDTO DataContract(IDataReader rdr)
        {
            var newItem = new RegionDataNameAndValueDTO
                          	{
                          		fieldName = rdr["fieldName"].ToString(),
                          		dataValue = rdr["dataValue"].ToString()
                          	};
			return newItem;
        }
    }
}
